package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.TravelexpensesMapper;
import com.ruoyi.system.domain.Travelexpenses;
import com.ruoyi.system.service.ITravelexpensesService;

/**
 * 出差报销Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-01-04
 */
@Service
public class TravelexpensesServiceImpl implements ITravelexpensesService 
{
    @Autowired
    private TravelexpensesMapper travelexpensesMapper;

    /**
     * 查询出差报销
     * 
     * @param id 出差报销主键
     * @return 出差报销
     */
    @Override
    public Travelexpenses selectTravelexpensesById(Long id)
    {
        return travelexpensesMapper.selectTravelexpensesById(id);
    }

    /**
     * 查询出差报销列表
     * 
     * @param travelexpenses 出差报销
     * @return 出差报销
     */
    @Override
    public List<Travelexpenses> selectTravelexpensesList(Travelexpenses travelexpenses)
    {
        return travelexpensesMapper.selectTravelexpensesList(travelexpenses);
    }

    /**
     * 新增出差报销
     * 
     * @param travelexpenses 出差报销
     * @return 结果
     */
    @Override
    public int insertTravelexpenses(Travelexpenses travelexpenses)
    {
        return travelexpensesMapper.insertTravelexpenses(travelexpenses);
    }

    /**
     * 修改出差报销
     * 
     * @param travelexpenses 出差报销
     * @return 结果
     */
    @Override
    public int updateTravelexpenses(Travelexpenses travelexpenses)
    {
        return travelexpensesMapper.updateTravelexpenses(travelexpenses);
    }

    /**
     * 批量删除出差报销
     * 
     * @param ids 需要删除的出差报销主键
     * @return 结果
     */
    @Override
    public int deleteTravelexpensesByIds(Long[] ids)
    {
        return travelexpensesMapper.deleteTravelexpensesByIds(ids);
    }

    /**
     * 删除出差报销信息
     * 
     * @param id 出差报销主键
     * @return 结果
     */
    @Override
    public int deleteTravelexpensesById(Long id)
    {
        return travelexpensesMapper.deleteTravelexpensesById(id);
    }
}
